/*
 * @Author: your name
 * @Date: 2021-02-24 13:59:57
 * @LastEditTime: 2021-02-24 14:15:08
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \mongoShell\insert1.js
 */
var startTime = (new Date()).getTime();//得到开始的时间
var db = connect('log');//链接数据库
//开始循环插入数据
for(let i = 0; i< 1000;i++){
    db.test1.insert({num:1});
}
var runtime = (new Date()).getTime() - startTime;//计算时间差
print('This run this is' + runtime + 'ms');//打印出来

